# NoX (NoC Simulator)
#
# Copyright (C) 2004-2006 by Dongkook Park, Ph.D Candidate,
# Dept. of Computer Science & Engineering, Pennsylvania State University.
# All Rights Reserved.
#  
# 1. License     
# NoX is distributed free of charge for academic, educational, noncommercial 
# research purposes as long as this notice in its entirety is preserved in
# every file included in this package.
# All commercial use of this program requires separate licence. Contact the
# author for details.
# 
# 2. All the publications that used the simulation results generated by the 
# NoX should notify the author of the publication information and put 
# following reference.
#
#  http://www.cse.psu.edu/~dpark/nox/
# 
# 3. Modification of the source code is permitted and encouraged as long as 
# it follows the terms described in this copyright notice.
#
# 4. The author is not responsible for any problems caused by possible errors
# of the NoX package. Therefore, users should verify the simulation result
# before using it in their publication.
#
# 5. NoX was developed and maintained by Dongkook Park, Ph.D Candidate,
# Dept. of Computer Science & Engineering, Pennsylvania State University.
# Contact: dpark@cse.psu.edu 
# 
# 6. If problems are found with the NoX package, please send an email to the
# author for discussion and correction.
#
# Copyright (C) 2004-2006 by Dongkook Park.
#
#
# Update History
#
# Jan. 31, 2006  Version 1.0 released by Dongkook Park 
#
# This is the compiler option.
#MySQL= -DUSE_MYSQL -I/usr/local/include/mysql/ -L/usr/local/lib/mysql/ -lz -lmysqlclient
MySQL= 

OPT = -O3
#OPT = -g

CXXFLAGS += $(OPT) 
#CXXFLAGS += $(OPT) -DTRACE_READ
#CXXFLAGS += $(OPT) -DTR_INTEG

EXE = .exe
OBJ = .o
CC=gcc
#BIN= 
BIN=bin/

OBJS=\
$(BIN)app$(OBJ)\
$(BIN)flit$(OBJ)\
$(BIN)flit_move$(OBJ)\
$(BIN)link$(OBJ)\
$(BIN)main$(OBJ)\
$(BIN)multimedia$(OBJ)\
$(BIN)nic$(OBJ)\
$(BIN)node_init$(OBJ)\
$(BIN)node_marking$(OBJ)\
$(BIN)route_adaptive$(OBJ)\
$(BIN)route_deterministic$(OBJ)\
$(BIN)route_proximity_aware$(OBJ)\
$(BIN)router$(OBJ)\
$(BIN)router_common$(OBJ)\
$(BIN)route_simple_ft$(OBJ)\
$(BIN)route_west_first$(OBJ)\
$(BIN)sim_init$(OBJ)\
$(BIN)sim_result$(OBJ)\

$(BIN)%.o: %.cpp
	   $(CC) $(CXXFLAGS) -c $< -o $@

nox:    $(OBJS)  
	$(CC) -o $(BIN)nox -g -lm -lz -lstdc++ $(OBJS) 
	rm $(OBJS)
clean : 
	rm $(OBJS) $(BIN)nox

all : noc_sim	
